<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<body>
    <!-- 顶部导航片段 -->
    <header class="header" th:fragment="header(pageTitle)">
        <div class="header-left">
            <h1 class="page-title" th:text="${pageTitle}">页面标题</h1>
        </div>
        <div class="header-right">
            <div class="search-box">
                <input type="text" placeholder="搜索...">
                <button>
                    <span data-icon="search"></span>
                </button>
            </div>
            <div class="notifications">
                <button>
                    <span data-icon="notification"></span>
                    <span class="badge">5</span>
                </button>
            </div>
            <div class="user-menu">
                <button id="userMenuBtn">
                    <div class="avatar">
                        <span>JD</span>
                    </div>
                    <span class="user-name">John Doe</span>
                    <span data-icon="chevron-down"></span>
                </button>
                <div class="dropdown-menu" id="userDropdown">
                    <a href="/profile">
                        <span data-icon="user"></span>
                        <span>个人资料</span>
                    </a>
                    <a href="/settings">
                        <span data-icon="settings"></span>
                        <span>账户设置</span>
                    </a>
                    <hr>
                    <a href="#" class="logout">
                        <span data-icon="logout"></span>
                        <span>退出登录</span>
                    </a>
                </div>
            </div>
        </div>
    </header>
</body>
</html> 